<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<title>CRS-o-matic</title>
		<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
		<link rel="stylesheet" type="text/css" href="css/main.css" />
		<link rel="stylesheet" type="text/css" href="css/jquery.paginate.css" />
		<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
		<script type="text/javascript" src="js/jquery.paginate.js"></script>
		<script type="text/javascript" src="js/pagination.js"></script>
	</head>
	<body>

		<div id="wrap">
			<div id="content">
				<strong>CRS-o-matic</strong> - a CRS schedule generator and probability and statistics tool written in pure Python<br />
				<br />
				This project is hosted at <a href="http://code.google.com/p/crs-o-matic/">Google Code</a>. For bug reports, feature requests, patch submissions, and the like, submit a new issue <a href="http://code.google.com/p/crs-o-matic/issues/list">here</a>.<br />
				<br />

				<strong>Terms:</strong>
				<ul>
					<li><em>probability</em> - the chances of getting a particular class; probability = 100% means a 'sure shot'.</li>
					<li><em>mean</em> - the mean of the probabilities of the classes in a particular schedule.</li>
					<li><em>standard deviation</em> - the standard deviation of the probabilities of the classes in a particular schedule.</li>
				</ul>

				<strong>NOTES:</strong>
				<ul>
					<li>You would want a schedule with a high probability mean and a low standard deviation.</li>
					<li>For classes with identical schedules, the probability is computed using the total demand and total available slots.</li>
				</ul>

				<strong>LIMITATIONS:</strong>
				<ul>
					<li>The parent-child relationship of classes is inferred from their sections.</li>
					<li>Course numbers with obscure naming formats might be unsupported.</li>
					<li>This may eat a lot of [server-side] resources when dealing with a large number of classes.</li>
				</ul>

				<strong>Disclaimer:</strong>
				<p>All data presented by CRS-o-matic ('The Software') are just parsed from the <a href="http://crs.upd.edu.ph/schedule">CRS website</a> and are not modified in any way. Thus, I will not be responsible for any misleading or erroneous information produced by the software due to inconsistencies or errors in the CRS website. I will also not be responsible for any misleading or erroneous information caused by bugs in the software. If you want to know how the software works, feel free to <a href="http://code.google.com/p/crs-o-matic/source/checkout">get the source</a>.</p>

			{% if desired %}
				<br />
				Desired classes:
				<ul>
				{% for c in desired.reg %}
					<li>{{ c.name }} ({{ c.credit }})</li>
				{% endfor %}
				{% for c in desired.extra %}
					<li>{{ c.name }} <em>({{ c.credit }})</em></li>
				{% endfor %}
				{% for c in desired.none %}
					<li><del>{{ c.name }}</del> <em>(no such class)</em></li>
				{% endfor %}
				</ul>

				{% if desired.matches %}

					Total number of units: <strong>{{ desired.units }}</strong>
					<br /><br />
					There {{ scheds|pluralize:"is,are" }} {{ scheds|length }} schedule{{ scheds|pluralize }} without conflicts out of {{ desired.possible }} possible schedule{{ desired.possible|pluralize }}:
					<br /><br />

					<div class="pagination"></div>

					{% for sched in scheds %}

						{% if forloop.counter|page_start %}
							 <div id="p{{ forloop.counter|page_id }}" class="page" style="display: none">
						{% endif %}

					<h2>{{ forloop.counter }}</h2>
					<table class="parent-table">
						<tr>
							<td class="first">
							{{ sched.get_table|safe }}
							</td>
							<td>
							{{ sched.get_stats|safe }}
							</td>
						</tr>
					</table>
					<br />

						{% if forloop.counter|page_end:scheds %}
							</div>
						{% endif %}

					{% endfor %}

					<div class="pagination"></div>

				{% endif %}

			{% else %}
				<form id="form" method="post" action="">
					<fieldset>
						Basic Filtering:<br />
						<strong>PE 2 TN</strong> - <em>all PE 2 lawn tennis classes</em><br />
						<strong>Geog 1</strong> - <em>all Geog 1 classes</em><br />
						<strong>Geog 1: TH</strong> - <em>all Geog 1 TH* classes (TTh by convention)</em><br />
						<strong>Geog 1: THQ</strong> - <em>all Geog 1 THQ* classes (includes THQ1, THQ2, and so on)</em><br />
						<strong>Geog 1: THQ1</strong> - <em>THE Geog 1 THQ1 class</em><br />
						<strong>Geog 1: !THQ</strong> - <em>all Geog 1 classes excluding THQ* classes</em><br />
						<br />
						Advanced Filtering:<br />
						<strong>Geog 1: TH, WFW</strong> - <em>all Geog 1 TH* and WFW* classes</em><br />
						<strong>Geog 1: TH, !THQ</strong> - <em>Geog 1 TH* classes excluding THQ* classes</em><br />
						<strong>Geog 1: TH, !THQ, WFW1, !THY</strong> - <em>Geog 1 TH* and WFW1 classes excluding THQ* and THY* classes</em><br />
						<br /><br />
						Term: <strong>{{ sem }}</strong><br />
						<label for="searchkey">Desired subjects (order by preference; case-insensitive; newline-separated):</label><br />
						<textarea id="searchkey" name="searchkey" rows="10" cols="20"></textarea><br />
						<input type="submit" value="Submit"/>
					</fieldset>
				</form>
			{% endif %}
				<p class="icon">
					<a href="http://validator.w3.org/check?uri=referer">
						<img src="http://www.w3.org/Icons/valid-xhtml10-blue" alt="Valid XHTML 1.0 Strict" height="31" width="88"/>
					</a>
					<a href="http://jigsaw.w3.org/css-validator/check/referer">
						<img style="border:0;width:88px;height:31px" src="http://jigsaw.w3.org/css-validator/images/vcss-blue" alt="Valid CSS!"/>
					</a>
				</p>
				<p class="copyright">
					Last Update: LAST_UPDATE_DATE<br />
					Copyright &copy; 2008-2012 <a href="http://www.darwin.uk.to/" title="Darwin M. Bautista">Darwin M. Bautista</a>
				</p>
			</div>
		</div>
	</body>
</html>
